package com.yxx.service;

import com.yxx.medicinecommon.result.PageResult;
import com.yxx.medicinepojo.dto.ChineseWesternMedicineDTO;
import com.yxx.medicinepojo.dto.ChineseWesternMedicinePageQueryDTO;
import com.yxx.medicinepojo.vo.ChineseWesternMedicineVO;

import java.util.List;

/**
 * @author yuxiangxun
 * @date 2024/9/11
 * @apiNote
 */
public interface ChineseWesternMedicineService {
    /**
     * 中西药管理分页
     * @param chineseWesternMedicinePageQueryDTO
     * @return
     */
    PageResult chineseWesternMedicinePage(ChineseWesternMedicinePageQueryDTO chineseWesternMedicinePageQueryDTO);

    /**
     * 根据分类id和中西药名称查询药品
     * @param categoryId
     * @return
     */
    List<ChineseWesternMedicineVO> list(Long categoryId,String name);

    /**
     * 中西药上架下架
     * @param status
     * @param id
     */
    void StartOrStop(Integer status, Long id);

    /**
     * 新增药品
     * @param chineseWesternMedicineDTO
     */
    void save(ChineseWesternMedicineDTO chineseWesternMedicineDTO);

    /**
     * 修改药品
     * @param chineseWesternMedicineDTO
     */
    void updateChineseWesternMedicine(ChineseWesternMedicineDTO chineseWesternMedicineDTO);

    /**
     * 回显数据，根据id查询药品
     * @param id
     * @return
     */
    ChineseWesternMedicineVO ChineseWesternMedicineSelectUpdateById(Long id);

    /**
     * 批量删除中西药
     * @param ids
     */
    void deleteChineseWesternMedicine(List<Long> ids);

    /**
     * 根据分类id查询药品
     * @param medicinecategoryId
     * @return
     */
    List<ChineseWesternMedicineVO> listByMedicineCategoryId(Long medicinecategoryId);
}
